home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / system / bywhen10.zip / RUNCHK.BAT < prev   
DOS Batch File  |  1995-01-09  |  1KB  |  48 lines

  1. @echo off
  2. cls
  3. goto setvars
  4. /////////////////////////////////////////////////////////////
  5. /  NAME: runchk.bat                                         /
  6. /  PURPOSE: execute DOS's chkdsk and redirect it's output   /
  7. /  DATE: 11/24/94                                           /
  8. /  NOTE: This is a test .bat for BYWHEN.EXE and is provided /
  9. /        as an example only for a BYWHEN.EXE demo.          /
  10. /        DO NOT execute while MS WINDOWS is running.        /
  11. /        Remove the @ if DOS ver prior to 3.30              /
  12. /////////////////////////////////////////////////////////////
  13.  
  14. :setvars
  15. set __chkdsk=chkdsk
  16. set __hdrive=c:
  17. set __errfil=c:\cddemo.rpt
  18. goto start
  19.  
  20. :start
  21. echo CHKDSK REPORT     > %__errfil%
  22. echo.                 >> %__errfil%
  23. %__chkdsk% %__hdrive% >> %__errfil%
  24. echo.                 >> %__errfil%
  25. if not exist %__errfil% goto nofind
  26. cls
  27. rem type %__errfil% | more
  28. more < %__errfil%
  29. goto cleanup
  30.  
  31.  
  32. :nofind
  33. echo.
  34. echo Problem with ChkDsk and creating %_errfil%
  35. echo.
  36. pause
  37. cls
  38. goto cleanup
  39.  
  40.  
  41. :cleanup
  42. set __errfil=
  43. set __hdrive=
  44. set __chkdsk=
  45. goto end
  46.  
  47. :end
  48.